<div class="_contro">
    <a href="/home/action/create?id=<?php echo $action['id'];?>&copy=1" class="_a"><font class="_font">复制该活动</font></a>&nbsp;&nbsp;
    <?php if($action['status']==1){?>
    <a href="/home/action/" class="_a"><font class="_font">返回</font></a>
    <?php }else{?>
    <a href="/home/action/release?action_id=<?php echo $action['id'];?>" onclick='' class="_a"><font class="_font maskLayer">发布</font></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
    <a href="/home/action/info?id=<?php echo $action['id'];?>" class="_a"><font class="_font">返回</font></a>
    <?php }?>
    <div style=' position: relative;;left:-90px;top:100px;' ><p><img src="/public/images/barbercode.jpg" style='width:100px;height:100px;' ></p><p>成员登录二维码</p> </div>
    <div style=' position: relative;;left:-83px;top:120px;' ><p><img src="/home/action/qrcode?action_id=<?php echo $action['id'];?>&store_id=<?php echo $action['store_id'];?>" style='width:120px;height:120px;' ></p><p style='margin-right:20px;'>活动二维码</p> </div> 
</div>
<div class='_cut'></div>

<div class="preview_div"  >

    <div class='_main'>
        <div style='height:1.5rem'></div>

        <div class="banner">
            <?php $image = explode('/',$action['logo']);$_img = array_pop($image);$image = implode('/',$image)."/"."max_".$_img; ?>
            <img src="<?php   if(strpos($action['logo'],'crowd.png')){ echo 'http://'.IMAGE_DOMAIN_.'/upload/crowd.png';}else{ echo 'http://'.IMAGE_DOMAIN_.$image; } ?>" class="banner_img"   alt='banner' />
        </div>
        <div  style='position: absolute;width:32rem;'>
            <div  style='float:left;margin-top:-4.5rem;' >
                <a href="#"><img src="/public/images/past_crowd.png" ></a>
            </div>
            <div style='float:right;text-align:center;margin-top:-5rem;'>
                <div style='height:10rem;width:10rem;'>
                <img src="/public/images/tou.png"  style="width:100%;height: 100%;border-radius:50%;overflow:hidden;">
                </div>
                <div style='height:1rem'></div>
                <p style="font-size:1.5rem;color:black;"><b> 爱心大使</b></p>
                <p style="margin-top:-1rem;font-size:1.5rem;color:black; text-overflow:ellipsis; white-space:nowrap; overflow:hidden;"><b>虚位以待</b></p> 
            </div>
        </div>


<script src="/public/js/islider.js"></script>
<script src="/public/js/islider_desktop.js"></script>
<?php $action['content'] = json_decode($action['content'],true);?>
<div style='height: 8rem'>
    <div class='_line'></div>
    <div class='_line'></div>
    <a href="#" onClick='opencode();'><b>点击－>关注公众号，查看订单。</b></a>
</div>
    <div class='box'>
        <div class="clearfix"></div>
        <h3><?php echo $action['action_name'];?></h3>
        <div style="height: 1rem"></div>
        <div class="box">
            <div ><img src="/public/images/crowd.png" style='width:15%;float:left;'></div>
            <div style='float: left;'>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</div>
            <div style='font-size:1.3rem;padding-left:17%;' >本活动为公益活动，【<?php echo $store['name']; ?>】承诺每成交一笔订单（注：<span style='color:red;'>订单完成是指到店完成消费</span>）将为KAKA公益捐助9.9元爱心基金用于【<?php echo $action['content']['crowd_name'];  ?>】项目的公益捐助，目前已成交<?php echo $count?$count:0;?>笔。</div>
            
            <div  style='clear:both;'></div>
            <div class='cut_3'></div>

        </div>
        <span class='colors-size'><?php echo $action['intro'];?></span>
    </div>

    <div class='_line'></div>
    <link href="/public/css/action.css" rel="stylesheet">

    <!-- 商品 list start -->

    <div class='box'>

        <?php  if($items){ $ids = $action['content']['ids']; $v = $items['0']; ?>

            
            <div style="width:100%">
                <div id="iSlider-effect-wrapper">
                    <div id="non-looping_<?php echo $v['id'];?>" class="iSlider-effect">
                        <img src="<?php echo 'http://'.IMAGE_DOMAIN_.$v['images'][0]['image'];?>" style='width:100%'/>
                    </div>
                    <div class='img_number'><?php echo count($v['images']);?>图</div>
                </div>
            </div>
            <div style="clear:both"></div>
                <div style="clear:both"></div>
                <script>
                /*var picList_<?php echo $v['id'];?> = [
                <?php foreach($v['images'] as $kk => $vv){ $image = explode('/',$vv['image']);$_img = array_pop($image);$image = implode('/',$image).'/'.'max_'.$_img;?>
                    {
                        width: '100%',
                            height: '100%',
                        content: "http://<?php echo IMAGE_DOMAIN_.$image;?>"
                    } <?php if ($kk + 1 < count($v['images'])){echo ','; }?>
                <?php } ?>
                ];
                //不循环 不自动播放
                var islider_<?php echo $v['id'];?> = new iSlider({
                    data: picList_<?php echo $v['id'];?>,
                dom: document.getElementById("non-looping_<?php echo $v['id'];?>"),
                    duration: 4000,
                    animateType: 'default',
                    isAutoplay: true,
                    isLooping: true,
                    hand: true,
                });
                islider_<?php echo $v['id'];?>.bindMouse();*/
            </script>
                <div>
                    <img src="/public/images/crowd_2.png" style='width:17%;float:left;margin-top:0.7rem;'>&nbsp;&nbsp;
                    <span class='big_title'><?php echo $v['name'];?></span>&nbsp;&nbsp;&nbsp;&nbsp;
                    <span class='small_title'><?php echo $v['title'];?></span>
                </div>
                <div class='cut_3'></div>
                <div class='cut'></div>
                <div class='cut_3'></div>
                <div>
                    <span class='_price'><s>原价：￥<?php echo $v['price']/100;?></s></span>
                    &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
                    <span class='_price'>爱心款：￥<?php echo $v['real_price'];?></span>
                </div>
                <div class='cut_3'></div>
                <div class='cut'></div>
                <div class='cut_3'></div>
                    <?php if($v['is_meal_set']==1){ ?>
                        <div class='set_content'>
                            套餐内容：<br/>
                            <?php foreach($v['meal_set_items'] as $kk=>$vv){ ?>
                            <a href="" ><b><?php echo $vv['name'];?></b></a>&nbsp;&nbsp;&nbsp;<?php echo $vv['number'];?>&nbsp;个/次<br/>
                            <?php }?>
                        </div>
                        <div class='cut_3'></div>
                        <div class='cut'></div>
                    <?php }?>
                <div class='cut_3'></div>
                <div class='intro colors-size'>
                    <?php echo $v['intro'];?>
<?php if(in_array($action['id'],array(219,220,221,222,223,224))){?>
        <img src='/image/ac.jpeg' style='width:100%'>
<?php }?> 
                </div>
                <div class='cut_3'></div>
                <div class='cut'></div>
                <div class='cut_3'></div>

        <?php }else{?>

                <i><?php foreach( $action['content']['content'] as $k=>$v ){
                    $v['old'] = $v['old']/100;$v['new'] = $v['new']/100;
                    echo "<span><h4>".$k."：原价<s><span style='color:red'>".$v['old']."</span></s>&nbsp;&nbsp;众筹价<span style='color:red'>".$v['new']."</span><br/>内容：<span style='color:red'>".$v['content']."</span></span></h4>";
                    }?>
                </i>

        <?php }?>

    </div>

    <!-- 商品 list end -->

        

        <div class='box'>
            <span class='colors'>活动日期:</span>
            <span class='colors-size'><?php echo date("Y年m月d日",$action['start_time']);?>&nbsp;至&nbsp;<?php echo date("Y年m月d日",$action['end_time']);?></span>
            </br>
            <span class="colors">使用截止日期:</span>
            <span class='colors-size'><?php echo date("Y年m月d日",$action['use_end_time']);?></span>
        </div>
        <div class='box'>
            <span class='colors'>联系人:</span>
            <span class='colors-size'><?php echo $store['person_charge'];?></span>
        </div>
        <div class='box'>
            <span class='colors'>Tel:</span>
            <span class='colors-size'><?php echo $store['tel'];?></span>
        </div>

        <div class='_line'></div>

        <div class='box'>
            <img style='width:100%' src='http://apis.map.qq.com/ws/staticmap/v2/?center=<?php echo $store["latlng"];?>&zoom=13&size=600*300&maptype=roadmap&markers=size:large|color:0xff0000|label:P|<?php echo $store["latlng"];?>&key=5LTBZ-Z6PC5-WAGIB-QXGAX-JBVBF-XQBTP'/>
        </div>

        <div class='_line'></div>

        <div class='box'>
            <span class='colors'>地址:</span>
            <span class='colors-size'><?php echo $store['address'];?></span>
        </div>

        <div class='_line'></div>

        <form id="form">
            <div class='box'>
                <input style="width:100%;height:3rem" type="text" value="" id="user_name" placeholder="请输入姓名"/>
            </div>
            <div class='_line3'></div>
            <div class='box'>
                <input style="width:100%;height:3rem" type="text" value="" id="mobile" placeholder="请填写手机号"/>
            </div>
            <div class='_line3'></div>
            <div class='box'>
                <input style='width:60%;height:3rem' type="text" value="" id="_code" placeholder="请填验证码">
                &nbsp;&nbsp;&nbsp;<button type="button" id='subcode' style='width:30%'>获取验证码</button>
            </div>
            <div class='_line3'></div>
                <input type="hidden" name="type_pay" id="type_pay" value="<?php echo $pay_status; ?>">
            <div class='box'>
                <select style="width:100%;height:3rem" name="type" id="type">
                <?php foreach($items as $v){
                    echo "<option value='".$v['id']."'>".$v['name']."</option>";
                }?>
                </select>
            </div>

        <div style="height:2rem"></div>

            <div  style="text-align: center;">
                    <button class="btn btn-primary btn-lg" id='_add' type="button" style="width:98%;background-color:#FF79BC;border-color:white">我要代言</button>
            </div>

<script type="text/javascript">
    function create()
    {
        setTimeout(window.location.href="/home/action/update?action_id="+<?php echo $action['id']; ?>);
    }
</script>
</div>